<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd" id="Definitions_1" targetNamespace="http://camunda.org/schema/1.0/bpmn">
  <bpmn2:process id="terminateEndEventExample" name="Default Process" isExecutable="true">
    <bpmn2:startEvent id="start">
      <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
    </bpmn2:startEvent>
    <bpmn2:parallelGateway id="ParallelGateway_1">
      <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
      <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
      <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
    </bpmn2:parallelGateway>
    <bpmn2:sequenceFlow id="SequenceFlow_2" sourceRef="start" targetRef="ParallelGateway_1"/>
    <bpmn2:userTask id="preNormalEnd" name="check before normal end">
      <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
      <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
    </bpmn2:userTask>
    <bpmn2:sequenceFlow id="SequenceFlow_4" sourceRef="ParallelGateway_1" targetRef="preNormalEnd"/>
    <bpmn2:subProcess id="SubProcess_1" name="SubProcess">
      <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
      <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
      <bpmn2:startEvent id="StartEvent_1">
        <bpmn2:outgoing>SequenceFlow_8</bpmn2:outgoing>
      </bpmn2:startEvent>
      <bpmn2:sequenceFlow id="SequenceFlow_8" name="" sourceRef="StartEvent_1" targetRef="EndEvent_1"/>
      <bpmn2:endEvent id="EndEvent_1">
        <bpmn2:incoming>SequenceFlow_8</bpmn2:incoming>
        <bpmn2:terminateEventDefinition id="TerminateEventDefinition_2"/>
      </bpmn2:endEvent>
    </bpmn2:subProcess>
    <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ParallelGateway_1" targetRef="SubProcess_1"/>
    <bpmn2:endEvent id="EndEvent_3">
      <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
    </bpmn2:endEvent>
    <bpmn2:sequenceFlow id="SequenceFlow_7" sourceRef="SubProcess_1" targetRef="EndEvent_3"/>
    <bpmn2:endEvent id="EndEvent_4">
      <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
    </bpmn2:endEvent>
    <bpmn2:sequenceFlow id="SequenceFlow_1" sourceRef="preNormalEnd" targetRef="EndEvent_4"/>
  </bpmn2:process>
  <bpmndi:BPMNDiagram id="preNormalEndDiagram" name="Default Process Diagram">
    <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="process_1">
      <bpmndi:BPMNShape id="BPMNShape_1" bpmnElement="start">
        <dc:Bounds height="36.0" width="36.0" x="110.0" y="198.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="BPMNShape_ParallelGateway_1" bpmnElement="ParallelGateway_1">
        <dc:Bounds height="50.0" width="50.0" x="196.0" y="191.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_2" sourceElement="BPMNShape_1" targetElement="BPMNShape_ParallelGateway_1">
        <di:waypoint xsi:type="dc:Point" x="146.0" y="216.0"/>
        <di:waypoint xsi:type="dc:Point" x="196.0" y="216.0"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNShape id="BPMNShape_UserTask_1" bpmnElement="preNormalEnd">
        <dc:Bounds height="50.0" width="110.0" x="275.0" y="268.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="BPMNShape_ParallelGateway_1" targetElement="BPMNShape_UserTask_1">
        <di:waypoint xsi:type="dc:Point" x="221.0" y="242.0"/>
        <di:waypoint xsi:type="dc:Point" x="221.0" y="292.0"/>
        <di:waypoint xsi:type="dc:Point" x="275.0" y="293.0"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNShape id="BPMNShape_EndEvent_2" bpmnElement="EndEvent_1">
        <dc:Bounds height="36.0" width="36.0" x="515.0" y="82.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="BPMNShape_SubProcess_1" bpmnElement="SubProcess_1" isExpanded="true">
        <dc:Bounds height="111.0" width="300.0" x="281.0" y="40.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_6" sourceElement="BPMNShape_ParallelGateway_1" targetElement="BPMNShape_SubProcess_1">
        <di:waypoint xsi:type="dc:Point" x="221.0" y="191.0"/>
        <di:waypoint xsi:type="dc:Point" x="221.0" y="95.0"/>
        <di:waypoint xsi:type="dc:Point" x="281.0" y="95.0"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNShape id="BPMNShape_EndEvent_3" bpmnElement="EndEvent_3">
        <dc:Bounds height="36.0" width="36.0" x="631.0" y="77.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="SequenceFlow_7" sourceElement="BPMNShape_SubProcess_1" targetElement="BPMNShape_EndEvent_3">
        <di:waypoint xsi:type="dc:Point" x="581.0" y="95.0"/>
        <di:waypoint xsi:type="dc:Point" x="631.0" y="95.0"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNShape id="BPMNShape_EndEvent_4" bpmnElement="EndEvent_4">
        <dc:Bounds height="36.0" width="36.0" x="435.0" y="275.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="BPMNShape_UserTask_1" targetElement="BPMNShape_EndEvent_4">
        <di:waypoint xsi:type="dc:Point" x="385.0" y="293.0"/>
        <di:waypoint xsi:type="dc:Point" x="435.0" y="293.0"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNShape id="BPMNShape_StartEvent_1" bpmnElement="StartEvent_1">
        <dc:Bounds height="36.0" width="36.0" x="303.0" y="82.0"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_8" bpmnElement="SequenceFlow_8" sourceElement="BPMNShape_StartEvent_1" targetElement="BPMNShape_EndEvent_2">
        <di:waypoint xsi:type="dc:Point" x="339.0" y="100.0"/>
        <di:waypoint xsi:type="dc:Point" x="515.0" y="100.0"/>
      </bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>
</bpmn2:definitions>